package com.healthcloud.service.impl;

import com.healthcloud.dao.WHospitalDao;
import com.healthcloud.entity.WHospitalEntity;
import com.healthcloud.service.WHospitalService;
import com.healthcloud.utils.PageParam;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;


@Transactional
@Service("wHospitalService")
public class WHospitalServiceImpl implements WHospitalService {
	@Autowired
	private WHospitalDao wHospitalDao;

	@Override
	public WHospitalEntity queryObject(Integer id){
		return wHospitalDao.queryObject(id);
	}

	@Override
	public List<WHospitalEntity> queryList(WHospitalEntity bean, PageParam pageParam){
		return wHospitalDao.queryList(bean, pageParam);
	}

	@Override
	public int queryTotal(WHospitalEntity bean){
		return wHospitalDao.queryTotal(bean);
	}

	@Override
	public void save(WHospitalEntity wHospital){
		wHospitalDao.save(wHospital);
	}

	@Override
	public void update(WHospitalEntity wHospital){
		wHospitalDao.update(wHospital);
	}

	@Override
	public void delete(Integer id){
		wHospitalDao.delete(id);
	}

	@Override
	public void deleteBatch(Integer[] ids){
		wHospitalDao.deleteBatch(ids);
	}

	@Override
	public WHospitalEntity getByHospitalCode(String hospitalCode) {
		return wHospitalDao.getByHospitalCode(hospitalCode);
	}

}
